/**
 * 
 */
package org.sensmon.core;

import org.sensmon.core.datamodel.Sensor;
import org.sensmon.gui.MainFrame;
import org.sensmon.gui.OptionsFrame;
import org.sensmon.gui.SensorFrame;

/**
 * @author LAP
 *
 */
public class GUIThread extends Thread{
	private MainFrame mainFrame;
	private OptionsFrame optionsFrame;
	private SensorFrame sensorFrame;
	
    private GUIThread() {
        super();
        mainFrame = new MainFrame();
        try {
			optionsFrame = new OptionsFrame();
		} catch (Exception e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
    }

	private static class FrameThreadHolder {
	        private final static GUIThread instance = new GUIThread();
	}

	public static GUIThread getInstance() {
	        return FrameThreadHolder.instance;
	}
	
	public MainFrame getMainFrame() {
		return mainFrame;
	}
	
	public OptionsFrame getOptionsFrame() {
		return optionsFrame;
	}
	
	public SensorFrame createSensorFrame() {
		sensorFrame = new SensorFrame();
		return sensorFrame;
	}
	
	public SensorFrame createSensorFrame(Sensor value) {
		return null;
	}
}
